//日期时间戳格式转化
export function parseTime(timestamp){
	const date = new Date(timestamp * 1000);
	
	const year = date.getFullYear();
	const month = date.getMonth() + 1;
	const day = date.getDate();
	const hours = date.getHours();
	const minutes = date.getMinutes();
	
	let formattedDatetime = 0
	if((month/10)<1){
		formattedDatetime = `${year}-0${month}-${day} ${hours}:${minutes}`;
	}else if((day/10)<1){
		formattedDatetime = `${year}-${month}-0${day} ${hours}:${minutes}`;
	}else{
		formattedDatetime = `${year}-${month}-${day} ${hours}:${minutes}`;
	}
	console.log(formattedDatetime);
	return formattedDatetime
}